﻿//////////////////////////////////////////////////////////////////////////////
//
//  Copyright © 1998-2024 Glodon Company Limited.  All rights reserved.
//
//  Use of this software is subject to the terms of the Glodon license
//  agreement provided at the time of installation or download, or which
//  otherwise accompanies this software in either electronic or hard copy form.  
//
//////////////////////////////////////////////////////////////////////////////

// Reviewed

#pragma once
#include "GcmpCommandAction.h"
#include "SnapTextPositionType.h"
#include "IObject.h"

namespace gcmp
{
    class ISnap;

    /// \brief 捕捉结果绘制器
    FINAL_INTERFACE class GCMP_COMMAND_ACTION_EXPORT ISnapRender : public IObject
    {
        DEFINE_CAST_DERIVED(gcmp::ISnapRender, gcmp::IObject);
    public:
        /// \brief 析构函数
        virtual ~ISnapRender() {}

        /// \brief 获取捕捉结果绘制器
        /// \return 捕捉结果绘制器指针
        static ISnapRender* Get();

        /// \brief 绘制捕捉结果
        /// \param snapResult 捕捉结果
        /// \param textPosition 捕捉文本相对于鼠标的位置
        /// \return void
        virtual void Draw(const ISnap* snapResult, SnapTextPositionType textPosition) = 0;

        /// \brief 对捕捉绘制进行清除
        /// \return void
        virtual void ClearSnapRenderData() = 0;

    };
}

